<?php
/*
 * Copyright (C) 2010 TopCoder Inc., All Rights Reserved.
 */
namespace protocol\translation\framework\services;

/**
 * <p>
 * The path to the src\php\main folder which will be used for including the source files to be tested.
 * </p>
 */
define('SRC_PATH', 'E:\Dev\TopCoder\PHP\alcatel-lucent_protocol_translation_framework\src\php\main');

/**
 * <p>
 * The path to the recess folder which contains the Recess Framework files
 * </p>
 */
define('DEP_PATH', 'E:/Dev/TopCoder/PHP/alcatel-lucent_protocol_translation_framework/test_files/dependencies/');
if (!isset($_ENV['dir.recess'])) {
    $_ENV['dir.recess'] = DEP_PATH;
}

/**
 * <p>
 * Helper class for the unit tests.
 * </p>
 *
 * @author akinwale
 * @version 1.0
 */
final class TestHelper {
    /**
     * <p>
     * Private constructor to prevent instantiation.
     * </p>
     */
    private function __construct() {

    }

    /**
     * <p>
     * Build a message body to be used for testing the converters.
     * </p>
     *
     * @param array $names the parameter names
     * @param array $values the corresponding values
     *
     * @return string the message body based on the specified names and values
     */
    public static function buildMessageBody($names = array(), $values = array()) {
        $ret = "";
        for ($i = 0; $i < count($names); $i++) {
            $ret .= $names[$i] . "=" . urlencode($values[$i]);
            if ($i != count($names) - 1) {
                $ret .= "&";
            }
        }

        return $ret;
    }
}

?>